/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
 *   Mupen64plus-core - m64p_config.h                                      *
 *   Mupen64Plus homepage: http://code.google.com/p/mupen64plus/           *
 *   Copyright (C) 2009 Richard Goedeken                                   *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 *   This program is distributed in the hope that it will be useful,       *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 *   GNU General Public License for more details.                          *
 *                                                                         *
 *   You should have received a copy of the GNU General Public License     *
 *   along with this program; if not, write to the                         *
 *   Free Software Foundation, Inc.,                                       *
 *   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.          *
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

/* This header file defines typedefs for function pointers to the Core's
 * configuration handling functions.
 */

#if !defined(M64P_CONFIG_H)
#define M64P_CONFIG_H

#include "m64p_types.h"

#ifdef __cplusplus
extern "C" {
#endif

m64p_error ConfigListSections(void *, void (*)(void *, const char *));
m64p_error ConfigOpenSection(const char *, m64p_handle *);
m64p_error ConfigListParameters(m64p_handle, void *, void (*)(void *, const char *, m64p_type));
m64p_error ConfigSaveFile(void);
m64p_error ConfigSaveSection(const char *);
int ConfigHasUnsavedChanges(const char *);
m64p_error ConfigDeleteSection(const char *SectionName);
m64p_error ConfigRevertChanges(const char *SectionName);
m64p_error ConfigSetParameter(m64p_handle, const char *, m64p_type, const void *);
m64p_error ConfigGetParameter(m64p_handle, const char *, m64p_type, void *, int);
m64p_error ConfigGetParameterType(m64p_handle, const char *, m64p_type *);
const char * ConfigGetParameterHelp(m64p_handle, const char *);
m64p_error ConfigSetDefaultInt(m64p_handle, const char *, int, const char *);
m64p_error ConfigSetDefaultFloat(m64p_handle, const char *, float, const char *);
m64p_error ConfigSetDefaultBool(m64p_handle, const char *, int, const char *);
m64p_error ConfigSetDefaultString(m64p_handle, const char *, const char *, const char *);
int          ConfigGetParamInt(m64p_handle, const char *);
float        ConfigGetParamFloat(m64p_handle, const char *);
int          ConfigGetParamBool(m64p_handle, const char *);
const char * ConfigGetParamString(m64p_handle, const char *);
const char * ConfigGetSharedDataFilepath(const char *);
const char * ConfigGetUserConfigPath(void);
const char * ConfigGetUserDataPath(void);
const char * ConfigGetUserCachePath(void);

#ifdef __cplusplus
}
#endif

#endif /* #define M64P_CONFIG_H */

